package com.sen.patterns.structural.adapter.ex2;

public class PegAdapter implements IRoundPeg, ISquarePeg {

	private IRoundPeg roundPeg;
	private ISquarePeg squarePeg;

	public PegAdapter(IRoundPeg roundPeg, ISquarePeg squarePeg) {
		this.roundPeg = roundPeg;
		this.squarePeg = squarePeg;
	}

	public void insert(String str) {
		squarePeg.insert(str);
	}

	public void insertIntoHole(String msg) {
		roundPeg.insertIntoHole(msg);
	}

}
